<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <script src="js/jquery-3.1.1.js"></script>
    <script src="js/base.js"></script>
</head>
<body>
    <img id="myinfo" height="200px" width="200px"/>
    <br>
    <button onclick="showMyInfo();">点击展示二维码名片</button>
<script>
    function showMyInfo(){
        let url="http://localhost:9001/kx/user/myinfo";
        let requestMethod="get";
        $.rest(requestMethod,url,null,function(data){
            if(data.code==200){
                let base64=data.result.qrCode;
                document.getElementById("myinfo").src="data:image/jpeg;base64,"+base64;
            }
        });
    }
</script>
</body>
</html>